package com.example.planetexploder.model.folder;

import android.content.Context;

import com.example.planetexploder.constants.FolderConst;

import java.io.File;

/**
 * 文件总操作类
 * @author 蒋子涵
 * 2019.10.15
 */
public class Folder implements FolderConst {

    private File root;

    public BookFolder bookFolder;
    public ImgFile imgFile;
    public TextFile textFile;

    public Folder(Context context)
    {
        root = context.getFilesDir();
        root = new File(root,ROOT_FOLDER_NAME);
        if(!root.exists())
            root.mkdir();
        bookFolder = new BookFolder(context, root);
        imgFile = new ImgFile(context, root);
        textFile = new TextFile(context, root);
    }

}
